package com.wantong.jianpu.fragments.main;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.ViewGroup;

import androidx.annotation.Nullable;

import com.wantong.jianpu.BR;
import com.wantong.jianpu.R;
import com.wantong.jianpu.base.BaseXFragment;
import com.wantong.jianpu.databinding.FragmentHomeBinding;
import com.wantong.jianpu.viewmodels.HomeViewModel;

/**
 * @author PACY
 * @date 2022/4/1
 * description: 首页
 */
public class HomeFragment extends BaseXFragment<FragmentHomeBinding, HomeViewModel> {

    public static HomeFragment newInstance(String title) {

        Bundle args = new Bundle();
        args.putString("title", title);
        HomeFragment fragment = new HomeFragment();
        fragment.setArguments(args);
        return fragment;
    }

    @Override
    public int initContentView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        return R.layout.fragment_home;
    }

    @Override
    public int initVariableId() {
        return BR.viewModel;
    }
}
